home *** CD-ROM | disk | FTP | other *** search
Text File | 1994-06-16 | 7.9 KB | 210 lines | [TEXT/ToyS] |
- tell application "THINK Project Manager"
- activate
-
- -- Modification Ph. Casgrain
- -- This extracts the full path to the THINK Project Manager folder
- -- with a little song and dance...
- try
- set projectManager to (choose file of type "APPL" with prompt ¬
- "Please locate the THINK Project Manager:") as string
- set oldDelims to text item delimiters of AppleScript
- set text item delimiters of AppleScript to {":"}
-
- set projectManagerPath to ""
- repeat with i from 1 to ((count of text items in projectManager) - 1)
- set projectManagerPath to projectManagerPath & (text item i of projectManager) & ":"
- end repeat
-
- set text item delimiters of AppleScript to oldDelims
- on error
- set text item delimiters of AppleScript to oldDelims
- end try
-
-
- -- Modification Ph. Casgrain
- -- Ask if the user has the C++ Libraries
- set libraryChoice to button returned of (¬
- display dialog "Do you have Symantec C++ or just plain C?" ¬
- buttons {"C++", "Plain C"})
- set doCPlusPlus to (libraryChoice = "C++")
-
- set RePrecompileFolderName to "(AppleScripts):"
-
- -- Modification Ph. Casgrain
- if doCPlusPlus then
- set RePrecompileProjectName to "RePrecompile++ π"
- else
- set RePrecompileProjectName to "RePrecompile π"
- end if
-
- -- RECOMPILE THE FOURTEEN STANDARD LIBRARIES
-
- set thisFolderName to "Standard Libraries:"
-
- set thisProjectName to "ANSI"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "ANSI—A4"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "ANSI—small"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "profile"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "unix"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- -- Modification Ph. Casgrain
- if doCPlusPlus then
- set thisProjectName to "ANSI++"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "ANSI—A4++"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "ANSI—small++"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "complex"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "CPlusLib"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "CPlusLib-A4"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "profile++"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "unix++"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- -- IOStreams uses unix++, so must be brought up to date after the unix++ project
- set thisProjectName to "IOStreams"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
- end if -- if doCPlusPlus
-
- -- RECOMPILE THE ONE MAC LIBRARY
-
- set thisFolderName to "Mac Libraries:"
-
- set thisProjectName to "SANE"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
-
- -- RECOMPILE THE TEN OOPS LIBRARIES
-
- set thisFolderName to "oops Libraries:"
-
- set thisProjectName to "oops"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "oopsA4"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "oopsDebug"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "oopsDebugFar"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "oopsFar"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- -- Modification Ph. Casgrain
- if doCPlusPlus then
- set thisProjectName to "oops++"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "oopsA4++"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "oopsDebug++"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "oopsDebugFar++"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
-
- set thisProjectName to "oopsFar++"
- open file (projectManagerPath & thisFolderName & thisProjectName)
- compile project document 1
- close project document thisProjectName saving «constant enumyes » with compacting
- end if -- if doCPlusPlus
-
- -- RE-PRECOMPILE THE TWO PRECOMPILED HEADERS
-
- -- first, just open our project so we can open the text files
- open file (projectManagerPath & RePrecompileFolderName & RePrecompileProjectName)
-
- -- now, precompile its source text files
- set thisFolderName to "Mac #includes:"
- set i to 1
- repeat while (i ≤ the (count of source of project document 1))
- copy (a reference to source i of project document 1) to thisSource
- copy ":" to thePrecompiledFileName
- if the name of thisSource is "Mac #includes.c" then
- copy "MacHeaders" to thePrecompiledFileName
- else if the name of thisSource is "Mac #includes.cp" or the name of thisSource is "Mac #includes.cpp" then
- copy "MacHeaders++" to thePrecompiledFileName
- end if
- if thePrecompiledFileName is not ":" then
- precompile thisSource to projectManagerPath & thisFolderName & thePrecompiledFileName with making
- else
- precompile thisSource with making
- end if
- set i to i + 1
- end repeat
-
- end tell
-